package cn.iocoder.yudao.module.erp.controller.admin.costinfo.vo;

import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
import cn.iocoder.yudao.module.erp.controller.admin.common.BaseCost;
import cn.iocoder.yudao.module.erp.enums.DictTypeConstants;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import java.time.LocalDate;
import java.util.*;
import java.math.BigDecimal;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import com.alibaba.excel.annotation.*;

@Schema(description = "管理后台 - 其他费用 Response VO")
/*@Data*/
@Getter
@Setter
@ExcelIgnoreUnannotated
public class CostInfoRespVO extends BaseCost {

    @Schema(description = "id", requiredMode = Schema.RequiredMode.REQUIRED, example = "25579")
    private Long id;

    @Schema(description = "费用类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
    @ExcelProperty("费用类型")
    private String type;

    @Schema(description = "关联公司", example = "23279")
    private Long customerId;

    private Long accountId;


    @ExcelProperty("关联公司")
    private String customerName;

    @Schema(description = "资金类型：0收入，1支出", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @ExcelProperty(value = "资金类型",converter = DictConvert.class)
    @DictFormat(DictTypeConstants.LNG_ERP_COST_TYPE)
    private Integer amountType;

    @Schema(description = "金额", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("金额")
    private BigDecimal amount;

    @Schema(description = "费用日期", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("费用日期")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDate getTime;

    public void setGetTime(LocalDate getTime) {
        this.getTime=getTime;
        this.setOrderTime(getTime);
    }

    @Schema(description = "备注", example = "你猜")
    @ExcelProperty("备注")
    private String remark;

    @Schema(description = "附件")
    private String fileUrl;

    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
    private LocalDateTime createTime;






}